import Main from '@/components/main'
import parentView from '@/components/parent-view'

export default [
  {
    path: '/login',
    name: 'login',
    meta: {
      title: 'Login - 登录',
      hideInMenu: true
    },
    component: () => import('@/view/login/login.vue')
  },
  {
    path: '/',
    name: '_home',
    redirect: '/home',
    component: Main,
    meta: {
      hideInMenu: true,
      notCache: true
    },
    children: [
      {
        path: '/home',
        name: 'home',
        meta: {
          hideInMenu: true,
          title: '首页',
          notCache: true,
          icon: 'md-home'
        },
        component: () => import('@/view/single-page/home')
      }
    ]
  },
  {
    path: '/luggage', // 必填    指定链接
    name: 'luggage', // 必填    组件名称，页面都以name值来加载
    component: Main, // 注入组件
    meta: {
      hideInBread: true
    },
    children: [ // 在main右侧视图显示的页面都要用children来添加
      {
        path: '/luggage', // 必填
        name: 'luggage', // 必填
        meta: {
          title: '行李查询', // 非必填   菜单名称
          icon: 'md-briefcase'// 非必填   菜单图标
        },
        component: () => import('@/view/luggage/luggage.vue') // 必填   用来加载该路由规则对应的视图
      }
    ]
  }
]
